<!--<?php
include_once PrintEot('left');
if(!$action){
if (!$job){print <<<EOT
-->
<script language="JavaScript" src="js/date.js"></script>
<form method="POST" action="$basename&job=list&">
<h2>评论搜索</h2>
<table width="100%" cellspacing="0" cellpadding="0">
	<tr class="tr3">
		<td width="30%">评论类型</td>
		<td><select name="type"><option value="">全部</option><option value="write">记录</option><option value="diary">日志</option><option value="photo">相片</option><option value="share">分享</option><option value="board">留言</option></select></td>
	</tr>
	<tr class="tr3">
		<td width="30%">评论内容（可使用通配符“*”）</td>
		<td><input type="text" name="title" value="" class="input"></td>
	</tr>
	<tr class="tr3">
		<td width="30%">作者名称（可使用通配符“*”）</td>
		<td><input type="text" name="username" value="" class="input"></td>
	</tr>
	<tr class="tr3">
		<td width="30%">发表日期</td>
		<td><input type="text" name="postdate_s" value="" id="postdate_s" onclick="javascript:ShowCalendar(this.id)" class="input"> - <input type="text" name="postdate_e" id="postdate_e" value="" onclick="javascript:ShowCalendar(this.id)" class="input"></td>
	</tr>
	<tr class="tr3">
		<td width="30%">排序</td>
		<td>发表时间 ：<input type="radio" name="ordertype" value="asc">升序 <input type="radio" name="oredertype" value="desc" checked="checked">降序</td>
	</tr>
	<tr class="tr3">
		<td width="30%">每页显示条数</td>
		<td><input type="text" name="lines" value="30" class="input" size="5"></td>
	</tr>
</table><br />
<center><input class="btn" value="提 交" type="submit"></center>
</form>
<!--
EOT;
} elseif ($job == 'list') {print<<<EOT
-->
<form method="POST" action="$basename&">
<input type="hidden" name="job" value="delete">
<input type="hidden" name="title" value="$title">
<input type="hidden" name="type" value="$type">
<input type="hidden" name="username" value="$username">
<input type="hidden" name="postdate_s" value="$postdate_s">
<input type="hidden" name="postdate_e" value="$postdate_e">
<input type="hidden" name="ordertype" value="$ordertype">
<input type="hidden" name="page" value="$page">
<input type="hidden" name="lines" value="$lines">
<table width="100%" cellspacing="0" cellpadding="0">
<tr><td class="tr4" colspan="14">评论列表</td></tr>
<tr class="tr3 s3">
	<td>ID</td>
	<td colspan="6" class="tac">内容</td>
	<td colspan=2>作者</td>
	<td colspan=2>发表时间</td>
	<td colspan=2>所属类型</td>
	<td class="tac">删除</td>
</tr>
<!--
EOT;
foreach ($commentdb as $key => $comment) {
if(!$comment['title'])continue;
$key+=($page-1)*$lines+1;
print <<<EOT
-->
<tr class="tr3">
	<td class="tac">$key</td>
	<td colspan="6" class="tac" title="$comment[title]">$comment[s_title]</td>
	<td colspan=2>$comment[username]</td>
	<td colspan=2>$comment[postdate]</td>
	<td colspan=2>$comment[ch_type]</td>
	<td class="tac"><input type="checkbox" name="selid[]" value="$comment[id]"></td>
</tr>
<!--
EOT;
}print<<<EOT
-->
</table><br />$pages
<center><input class="btn" type='button' name='chkall' value='全 选' onclick='CheckAll(this.form)'>
<input type="submit" value='提 交' class="btn" onclick="return checkdel();"></center>
</form>
<script language="JavaScript">
function checkdel(){
	if(confirm("确定要删除所选评论吗？" )){
		return true;
	}else{
		return false;
	}
}
</script>
<!--
EOT;
}
}include_once PrintEot('adminbottom');
?>-->